<?
//******************************************************************************
//******************************************************************************
//***    Page des Comptes.                                                   ***
//***          Par Khiguard.                                                 ***
//***                 Le 05-01-2003.                                         ***
//******************************************************************************
//******************************************************************************


$query="SELECT user_mail,user_inscription,user_ancien_log,user_niv,user_exp,user_perso,user_forum_avatar, user_forum_signature,user_multicompte,user_niv, user_exp, user_exp_tmp FROM sdusers where user_id='$userid'";
$resultat=mysql_query($query);
$tmp=mysql_fetch_row($resultat);

$perso=$tmp[5];



   $inscription=$tmp[1];

   $log=$tmp[2];


?><br>
<u><strong></strong></u> 
<table width="95%" height="20" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#000000">
  <tr> 
    <td ><table width="100%" border="0" cellspacing="1">
        <tr> 
          <td CLASS="TD2"> <div align="center"> 
              <u><b><font color="#FFFF00" size="4"><? echo $_USER_NAME;?></font></b></u> 
            </div></td>
        </tr>
      </table></td>
  </tr>
</table>
<br>
<table width="95%" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#000000">
  <tr> 
    <td ><table width="100%" border="0" cellspacing="1">
        <tr> 
          <td CLASS="TD3">
<div align="center"><font size="2"><a href="<? echo"?p=changepass&$SID" ?>"><br>
              </a></font> 
              <table width="75%" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#000000">
                <tr> 
                  <td ><table width="100%" border="0" cellspacing="1">
                      <tr> 
                        <td CLASS="TD2"> 
                          <div align="center"><strong><font size="2"><a href="<? echo"?p=changepass&$SID" ?>">Changer 
                            password.</a></font></strong> <br>
                          </div></td>
                      </tr>
                    </table></td>
                </tr>
              </table>
              <br>
              <table width="95%" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#000000">
                <tr> 
                  <td ><table width="100%" border="0" cellspacing="1">
                      <tr> 
                        <td CLASS=TD2> 
                          <div align="center">
                            <form name="form1" method="post"  action="site/test/include.php" target="frame_test" >
                                    <div align="center"> 
                                      
                                <div align="center"><strong><font size="5"></font></strong></div>
                                      
                                <table width="85%" border="0" cellspacing="0" cellpadding="0">
                                  <tr> 
                                    <td> <fieldset CLASS="TD1" width="50%">
                                      <legend> <font size="2"><B>Compte</B></font> 
                                      </legend>
                                      <table width="95%" border="0" align="center" cellpadding="0" cellspacing="2">
                                        <tr valign="middle"> 
                                          <td width="10%"> 
                                            <div align="right"><strong><u><font size="2"><strong><u>E-mail</u></strong></font> 
                                              </u></strong></div></td>
                                          <td valign="bottom">
<input name="mail" type="text" id="mail2" value="<? echo $tmp[0]?>" size="35" maxlength="70"></td>
                                        </tr>
                                      </table>
                                      </fieldset></td>
                                  </tr>
                                </table>
                                <table width="85%" border="0" cellspacing="0" cellpadding="0">
                                  <tr> 
                                    <td> <fieldset CLASS="TD1" width="50%">
                                      <legend> <font size="2"><B>Forum</B></font> 
                                      </legend>
                                      <table width="95%" border="0" align="center" cellpadding="0" cellspacing="2">
                                        <tr valign="middle"> 
                                          <td width="10%"> <div align="right"><strong><u> 
                                              <?
IF (!empty($tmp[6])){

ECHO "<img src=$tmp[6]>";
}

    
echo"<input name=\"p\" type=\"hidden\" id=\"p\" value=\"chg_profil\">";

?>
                                              </u></strong></div></td>
                                          <td width="9%" valign="bottom"> <p align="right"><font size="2"><strong><u>Avatar 
                                              : </u></strong></font> </p></td>
                                          <td width="69%" valign="bottom"><input name="avatar" type="text" id="avatar" size="50" maxlength="255" value="<? echo $tmp[6]; ?>" class="effect"></td>
                                        </tr>
                                        <tr valign="middle"> 
                                          <td align="right" valign="top"><font size="2"><strong><u>Signature 
                                            : </u></strong></font></td>
                                          <td colspan="2" valign="bottom"><textarea name="signature" cols="45" rows="6" class="effect" id="textarea"><? echo $tmp[7]; ?></textarea></td>
                                        </tr>
                                      </table>
                                      </fieldset></td>
                                  </tr>
                                </table>
                                <br>
                                <table width="85%" border="0" cellspacing="0" cellpadding="0">
                                  <tr> 
                                    <td> <fieldset CLASS="TD1" width="50%">
                                      <legend> <font size="2"><B>Multicompte</B></font> 
                                      </legend>
                                      <table width="95%" border="0" align="center" cellpadding="0" cellspacing="2">
                                        <tr valign="middle"> 
                                          <td width="10%" align="right" valign="top"><font size="2"><strong><u>D&eacute;tail:</u></strong></font></td>
                                          <td width="78%" valign="bottom"><textarea name="multicompte" cols="45" rows="6" class="effect" id="textarea4"><? echo $tmp[8]; ?></textarea></td>
                                        </tr>
                                        <tr valign="middle"> 
                                          <td colspan="2" align="right" valign="top"><div align="left"> 
                                              <p><font size="2"><strong>Veuillez 
                                                indiquer ici si vous gerer un 
                                                compte d'un ami, si d'autre que 
                                                vous utilis&eacute; le m&ecirc;me 
                                                ordinateur (famille, etc...) et 
                                                si oui: quel autres compte.<br>
                                                Ceci dans un esprit de claret&eacute;, 
                                                car si nous voyons que votre compte 
                                                a des point commun avec un autre, 
                                                nous pourrions le prendre pour 
                                                un multicompte et l'&eacute;ffacer 
                                                sans pr&eacute;avis.<br>
                                                Ces informations, pourraient nous 
                                                aider &agrave; &eacute;claircir 
                                                la situation.</strong></font> 
                                              </p>
                                              </div></td>
                                        </tr>
                                      </table>
                                      </fieldset></td>
                                  </tr>
                                </table>
                                <p>
                                  <input type="submit" name="Submit" value="Envoyer">
                                </p>
                                </div>
                                  </form>
                          </div></td>
                      </tr>
                    </table></td>
                </tr>
              </table>
              
              <br>
              <table width="95%" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#000000">
                <tr> 
                  <td ><table width="100%" border="0" cellspacing="1">
                      <tr> 
                        <td CLASS="TD2"> 
                          <div align="center"> 
                            <table width="95%" align="center" cellpadding="0" cellspacing="0">
                              <tr> 
                                <td width="51%" height="24"> <div align="center"> 
                                    <table width="85%" border="0" cellspacing="0" cellpadding="0">
                                      <tr> 
                                        <td> <fieldset CLASS="TD1" width="50%">
                                          <legend> <font size="2"><B>Niveau de 
                                          l'utilisateur</B></font> </legend>
                                          <table width="95%" border="0" align="center" cellpadding="0" cellspacing="2">
                                            <tr valign="middle"> 
                                              <td> <div align="left"><strong><font size="2"><strong><? echo $tmp[9]; ?></strong></font></strong></div></td>
                                            </tr>
                                          </table>
                                          </fieldset></td>
                                      </tr>
                                    </table>
                                  </div></td>
                                <td width="49%"> <div align="center"> 
                                    <table width="85%" border="0" cellspacing="0" cellpadding="0">
                                      <tr> 
                                        <td> <fieldset CLASS="TD1" width="50%">
                                          <legend> <font size="2"><B>Point d'exp&eacute;rience 
                                          global </B></font> </legend>
                                          <table width="95%" border="0" align="center" cellpadding="0" cellspacing="2">
                                            <tr valign="middle"> 
                                              <td> <div align="left"><strong><font size="2"> 
                                                  <? $exp= $tmp[10]+$tmp[11]; echo "$exp"; ?>
                                                  </font></strong></div></td>
                                            </tr>
                                          </table>
                                          </fieldset></td>
                                      </tr>
                                    </table>
                                  </div></td>
                              </tr>
                            </table>
                            <br>
                          </div></td>
                      </tr>
                    </table></td>
                </tr>
              </table>
              <br>
              <table width="95%" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#000000">
                <tr> 
                  <td ><table width="100%" border="0" cellspacing="1">
                      <tr> 
                        <td CLASS="TD2"> 
                          <div align="center"> 
                            <table width="95%" align="center" cellpadding="0" cellspacing="0">
                              <tr> 
                                <td width="51%" height="24"> <div align="center"> 
                                    <table width="85%" border="0" cellspacing="0" cellpadding="0">
                                      <tr> 
                                        <td> <fieldset CLASS="TD1" width="50%">
                                          <legend> <font size="2"><B>Date d'inscription</B></font> 
                                          </legend>
                                          <table width="95%" border="0" align="center" cellpadding="0" cellspacing="2">
                                            <tr valign="middle"> 
                                              <td> <div align="left"><strong><font size="2"><strong><? echo $inscription; ?></strong></font></strong></div></td>
                                            </tr>
                                          </table>
                                          </fieldset></td>
                                      </tr>
                                    </table>
                                  </div></td>
                                <td width="49%"> <div align="center"> 
                                    <table width="85%" border="0" cellspacing="0" cellpadding="0">
                                      <tr> 
                                        <td> <fieldset CLASS="TD1" width="50%">
                                          <legend> <font size="2"><B>Derni&egrave;re 
                                          visite </B></font> </legend>
                                          <table width="95%" border="0" align="center" cellpadding="0" cellspacing="2">
                                            <tr valign="middle"> 
                                              <td> <div align="left"><strong><font size="2"><? echo "$log"; ?></font></strong></div></td>
                                            </tr>
                                          </table>
                                          </fieldset></td>
                                      </tr>
                                    </table>
                                  </div></td>
                              </tr>
                            </table>
                            <br>
                          </div></td>
                      </tr>
                    </table></td>
                </tr>
              </table>
              <br>
            </div></td>
        </tr>
      </table></td>
  </tr>
</table>
<?
ECHO"<BR><table width=\"95%\" height=\"20\" border=\"0\" align=\"center\" cellpadding=\"0\" cellspacing=\"0\" bgcolor=\"#000000\">
  <tr> 
    <td ><table width=\"100%\" border=\"0\" cellspacing=\"1\">
        <tr> 
          <td CLASS=\"TD3\"> <div align=\"center\"><u><strong><font color=\"#FFFFFF\" size=\"2\"> 
		Effacement de votre compte.</font></strong></u></div></td></tr><tr><td CLASS=\"TD2\"><strong><u><font color=\"#FFFFFF\" size=\"2\">Attention:</font></u></strong><font color=\"#FFFFFF\" size=\"2\"><br>
            Si vous utiliser cette option, votre compte utilisateur sera effac&eacute; 
            pour de bon. Il n'y aura aucun moyen de le recuperer.<br>
            Vous ne pouvez utiliser cette option que si vous avez effacer votre 
            personnage avant.</font>";

SWITCH ($perso){
	CASE 0:
	echo"<BR><BR><CENTER><form name=\"formx\" method=\"post\" action=\"accueil.php\">
         <input type=\"hidden\" name=\"p\" type=\"p\" id=\"p\" value=\"test-option\">
	    <input name=\"choix2\" type=\"hidden\" id=\"choix2\" value=\"del_compte\">
          <input name=\"$SID\" type=\"hidden\" id=\"$SID\" value=\"$SID\">
  <input type=\"submit\" name=\"Submit\" value=\"Effacer Votre Compte\">
</form><CENTER>";
	BREAK;
	DEFAULT:
	
BREAK;
}//Fin switch $perso			
			
			
        echo"</td></tr></table></td></tr></table>";
?>
